-- GENERATED SPELL FOR [Ashenvale Outrunner] --


function spell0_12856(pUnit, Event) --@Ashenvale Outrunner Sneak,Self--
pUnit:FullCastSpellOnTarget(20540,pUnit)
pUnit:RegisterEvent('Sorts_12856', 596, 1)
end

function spell1_12856(pUnit, Event) --@Scorpid Sting,n/a--
pUnit:FullCastSpellOnTarget(18545,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_12856', 20345, 1)
end

function spell2_12856(pUnit, Event) --@Shoot,n/a--
pUnit:FullCastSpellOnTarget(6660,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_12856', 606, 1)
end

function spell3_12856(pUnit, Event) --@Snap Kick,n/a--
pUnit:FullCastSpellOnTarget(8646,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_12856', 2317, 1)
end

function Sorts_12856(pUnit, Event)
local choix_sorts_12856 = math.random(0, 3)
if choix_sorts_12856 == 0 then
pUnit:RegisterEvent('spell0_12856', 1, 1)
end
if choix_sorts_12856 == 1 then
pUnit:RegisterEvent('spell1_12856', 1, 1)
end
if choix_sorts_12856 == 2 then
pUnit:RegisterEvent('spell2_12856', 1, 1)
end
if choix_sorts_12856 == 3 then
pUnit:RegisterEvent('spell3_12856', 1, 1)
end
end

function mob12856_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_12856', math.random(1500, 3000), 1)
end

function mob12856_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob12856_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob12856_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(12856, 1, 'mob12856_Action')
RegisterUnitEvent(12856, 2, 'mob12856_Leave')
RegisterUnitEvent(12856, 3, 'mob12856_Kill')
RegisterUnitEvent(12856, 4, 'mob12856_Die')
